package com.yzh.dxpro.p10.taskTen;
import java.io.IOException;
import org.apache.hadoop.io.IntWritable;
import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;

import com.yzh.dxpro.p1.clear.TProperties;

public class TenMapper extends Mapper<LongWritable, Text, Text, IntWritable>{
	Text okey=new Text();
	IntWritable ovalue =new IntWritable(1);
	int i=0;
	@Override
	protected void map(LongWritable key, Text value, Mapper<LongWritable, Text, Text, IntWritable>.Context context)
			throws IOException, InterruptedException {
		// TODO Auto-generated method stub
		String[] values=value.toString().split(TProperties.getValue("fileoutsplit"));
		okey=new Text(values[1]+TProperties.getValue("outfilesplit")+values[4]);
		
		context.write(okey, ovalue);
		while(i<3) {
			context.write(new Text("513047654667|2"), ovalue);
			i++;
		}
	}
	
	

}
